<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib uri="/struts-tags" prefix="s"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<script type="text/javascript" src="${pageContext.request.contextPath }/js/jquery-1.8.3.js"></script>
<script type="text/javascript"
	src="${pageContext.request.contextPath }/js/easyui/jquery.easyui.min.js" /></script>
	<!-- 导入easyui类库 -->
<link id="easyuiTheme" rel="stylesheet" type="text/css"
	href="${pageContext.request.contextPath }/js/easyui/themes/default/easyui.css">
<link rel="stylesheet" type="text/css"
	href="${pageContext.request.contextPath }/js/easyui/themes/icon.css">
	
<script type="text/javascript">

	var toolbar = [
	               {text:'添加',iconCls:'icon-add',handler:function(){alert('add...');}},
	               {text:'删除',iconCls:'icon-remove'},
	               {text:'修改',iconCls:'icon-edit'}
	               ];
	$(function(){
		$("#grid").datagrid({
			columns:[[
			          {field:'id',title:'编号'},
			          {field:'name',title:'姓名'},
			          {field:'age',title:'年龄'}
			          ]],
			url:'${pageContext.request.contextPath}/json/data.json',
			pagination:true,
			striped:true,
			toolbar:toolbar,
			//pagePosition:'top'
			pageList:[20,30,40,50]
		});
	});
</script>
</head>
<body>
	<table id="grid"></table>
</body>
</html>